package com.example.demo.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

// @RestController 注解: 相当于 @Controller + @ResponseBody
@RestController
public class HelloWorldController {

    // @RequestMapping(value = "hello", method = RequestMethod.GET)
    @RequestMapping("/hello")
    public String myFristSpringBoot() {
        return "hello world";
    }
}
